#include <vector>
#include <string>
#include <iostream>
#include "split_string.h"
#include "split_string_test.h"
using std::string;
using std::vector;
vector<string> split(const string& line, char x)
{

	vector <string> elems;
	int pos = 0;
	int len = line.length();
	if(x == 0){
		return elems;
	}
	while(pos<len) {
		int find_pos = line.find(x,pos);
		if(find_pos <=0){
			elems.push_back(line.substr(pos,len-pos));
			break;
			
		}
		elems.push_back(line.substr(pos,find_pos-pos));
		pos = find_pos+1;
		return elems;
		
		}
	//TODO: home {work below
}
	//TODO: home work below

